<template>
  <swiper indicator-dots autoplay :interval="3000" :duration="1000" circular indicator-color="ivory" indicator-active-color="#d43c33" class="banners">
    <swiper-item v-for="item in bannerList" :key="item.bannerId"><image :src="item.pic"></image></swiper-item>
  </swiper>
</template>

<script>
export default {
  name: 'my-swiper',
  props: {
    // 轮播图数据
    bannerList: {
      type: Array,
      default: []
    }
  },
  data() {
    return {};
  }
};
</script>

<style lang="scss">
.banners {
  width: 100%;
  height: 300rpx;

  image {
    width: 100%;
    height: 100%;
  }
}
</style>
